import { HttpException } from './http.exception';

// 基础权限异常
export class ForbiddenException extends HttpException {
  constructor(message: string = '无权限') {
    super(403, message);
  }
}

export class RoleNotAssignedException extends HttpException {
  constructor(message: string = '用户未分配角色') {
    super(403, message);
  }
}

export class RoleDisabledException extends HttpException {
  constructor(message: string = '角色已被禁用') {
    super(403, message);
  }
}

export class MaintenanceModeException extends HttpException {
  constructor(message: string = '系统维护中，暂时无法访问') {
    super(503, message);
  }
}

export class IPRestrictedException extends HttpException {
  constructor(message: string = 'IP地址受限') {
    super(403, message);
  }
}
